home *** CD-ROM | disk | FTP | other *** search
/ Aminet 40 / Aminet 40 (2000)(Schatztruhe)[!][Dec 2000].iso / Aminet / misc / emu / ATUtilities.lha / ATUtilities / BASIC / 3D.BAS next >
BASIC Source File  |  2000-09-26  |  623b  |  31 lines

  1. screen 12
  2.  
  3. color 3
  4. call DrawQ4(150,400, 200,200,100)
  5.  
  6. end
  7.  
  8. sub DrawQ4(x,y,w,h,d) static
  9.  call DrawLine(x,y,0,x+w,y,0)
  10.  call DrawLine(x,y,0,x,y,d)
  11.  call DrawLine(x,y,0,x,y-h,0)
  12.  call DrawLine(x+w,y,0,x+w,y-h,0)
  13.  call DrawLine(x+w,y,0,x+w,y,d)
  14.  call DrawLine(x,y-h,0,x+w,y-h,0)
  15.  call DrawLine(x,y,d,x+w,y,d)
  16.  call DrawLine(x+w,y-h,0,x+w,y-h,d)
  17.  call DrawLine(x,y-h,0,x,y-h,d)
  18.  call DrawLine(x+w,y-h,d,x+w,y,d)
  19.  call DrawLine(x,y-h,d,x,y,d)
  20.  call DrawLine(x,y-h,d,x+w,y-h,d)
  21. end sub
  22.  
  23. sub DrawLine(x1,y1,z1, x2,y2,z2) static
  24.  xa=x1+z1
  25.  ya=y1-z1
  26.  xb=x2+z2
  27.  yb=y2-z2
  28.  line (xa,ya)-(xb,yb)
  29. end sub
  30.  
  31.